{template "member","header"}
<div id="main">
{template "message","left"}
	<div id="right">
		<p id="position"><strong>当前位置：</strong><a href="{$M[url]}index.php">短消息</a>收件箱</p>
        <form name="myform" id="myform" method="post" action="{$M[url]}inbox.php">
    	 <table cellpadding="0" cellspacing="1" class="table_list">
         <caption>
      		{$anoucement}
      	  </caption>
        <tr>
        	<th width="5%">选中</th>
         	<th width="*">标题</th>
			<th width="10%">回复数</th>
           	<th width="10%">发件人</th>
			<th width="20%">发送时间</th>
        </tr>
        {loop $arr_message $msg}
        <tr>
        	<td><input type="checkbox" name="arr_msgid[]" class="input_1" id="checkbox" value="{$msg['messageid']}" /></td>
            <td  class="align_left"><a href="{$M[url]}read.php?userid={$_userid}&msgid={$msg['messageid']}">{if $msg['status'] == 1}<strong class="c_orange">{$msg['subject']}</strong>{else}{$msg['subject']}{/if}</a></td>
			<td>{$msg['num_reply']}</td>
            <td><a href="<?=space_url($msg['send_from_id'])?>" target="_blank">{username($msg['send_from_id'])}</a></td>
			<td>{$msg['date']}</td>
        </tr>
        {/loop}
		<tr>
			<td colspan="5" style="text-align:left;">
				<input type="hidden" id="action" name="action" value="delete" />
				&nbsp;&nbsp; &nbsp;&nbsp;
				<input type="button" name="arr_msgid" onclick='checkall()' value="全选" />
				&nbsp;
				<input type="button" name="export" id="export" value="导出" />
				&nbsp;
				<input type="button" name="dosubmit" id="delete" value="删除" onClick="if(confirm('确认批量删除这些消息吗？')) $('form').submit();return false;" />
			</td>
		</tr>
		</table>
		</form>
		<div id="pages">{$pages}</div>
		{if $url == 'inbox.php'}
		<table cellpadding="0" cellspacing="1" class="table_info">
			<caption>提示信息</caption>
			<tr>
				<td>可保存{$G['allowmessage']}条短消息</td>
			</tr>
		</table>
		{/if}
	</div>
</div>
<div class="clear"></div>
<div id="toogle_panel"></div>
{template "member","footer"}
<script language="javascript">
	$("#export").click(function(){
		$('#action').val('export');
		$('form').submit();
	});
</script>